﻿






function IfChangeColor(changeColor) {
    if (changeColor == 1) {
        ChangeColor = "#000000"
    } else if (changeColor == 2) {
        ChangeColor = "#379cda"
    } else if (changeColor == 3) {
        ChangeColor = "#4ea252"
    } else if (changeColor == 4) {
        ChangeColor = "#445a66"
    } else if (changeColor == 5) {
        ChangeColor = "#f3e6d4"
    } else if (changeColor == 6) {
        ChangeColor = "#2c9bcb"
    } else if (changeColor == 7) {
        ChangeColor = "#a83d3b"
    } else {
        ChangeColor = "#4caf50";
    }
}
//IfChangeColor(entity.ChangeColor);

IfChangeColor("#0000000");

TitleModule = [
    [
        '<div class="titlemodle" data-index="0" data-in="s" data-se="false" class="m-title-base"><div data-clistyle-brushtype=" bd" class="change-color-find" change-color="0" style="max-width: 100%; top: 0px; padding: 6px 10px; margin: 0px; border-color: ' + ChangeColor + '; border-left-width: 5px; border-left-style: solid; background-color: #f5f5f5;color: #333; font-family: Microsoft Yahei; white-space: normal;word-wrap: break-word;line-height: 24px;  vertical-align: baseline; "><span style="padding: 0px; margin-top: 0px; margin-bottom: 0px; font-size: 16px;" class="titlemodle-find">',
        '</span></div></div>'
    ],
    [
        '<div class="titlemodle" data-index="1" data-in="s" data-se="false" class="m-title-base"><div style="border:0;margin-top:18px; padding: 0.5em 0;white-space: normal;border: none;border-top: 1px solid #ccc;display: block; font-size: 1em; font-family: inherit; font-style: normal;font-weight: inherit; text-decoration: inherit; color: #a6a6a6;font-family:Microsoft Yahei;"><div style="margin-top: -1.2em;text-align: center;text-align: center; padding: 0; border: none; line-height: 1.4;"><span data-clistyle-brushtype="bg" class="change-color-find"  change-color="1" style="background-color:' + ChangeColor + '; padding:8px 23px; border-radius: 2px; color:#fff; font-family:inherit; font-size: 14px; font-style:normal; font-weight:inherit; text-align:center; text-decoration:inherit" class="titlemodle-find">',
        '</span></div></div></div>'
    ],
    [
        '<div class="titlemodle" data-index="2" data-in="s" data-se="false" class="m-title-base"><div data-clistyle-brushtype="bd" class="change-color-find" change-color="2" style="white-space: normal; margin: 5px 0px 0px; padding: 5px 15px; max-width: 100%; border-left-width: 5px; border-left-style: solid; border-left-color: ' + ChangeColor + '; line-height: 25px; color:#666;"><p style="margin:0;font-family:Microsoft Yahei;font-size:16px;" class="titlemodle-find">',
        '</p></div></div>'
    ],
    [
        '<div class="titlemodle" data-index="3" data-in="s" data-se="false" class="m-title-base"><div style="font-size:14px;font-family:Microsoft YaHei;margin: 5px auto;white-space: normal;"><div style="margin:5px auto;padding:0;white-space:normal;border:none;border-style:none;text-align:center"><div data-clistyle-brushtype="bd" class="change-color-find" change-color="31" style="width:100%;border-bottom-style:solid;border-bottom-width:1px; border-color:' + ChangeColor + ';display:inline-block"><div data-clistyle-brushtype="bd" class="change-color-find" change-color="32" style="min-height:30px;color:#333;display:inline-block;border-bottom-width:5px;border-bottom-style:solid;border-color: ' + ChangeColor + ';padding:5px 10px 0;margin-bottom:-3px;font-size:16px"><p style="margin-bottom:5px" class="titlemodle-find">',
        '</p></div></div></div></div></div>'
    ],
    [
        '<div class="titlemodle" data-index="4" data-in="s" data-se="false" class="m-title-base"><div style="font-size:14px;margin: 5px auto;white-space: normal;"><div style="margin:5px 0;padding:0;text-align:center;"><div style="margin:0;padding:0;display:inline-block"><div data-clistyle-brushtype="bg" class="change-color-find"  change-color="41" style="margin:0;padding:0;width:6px;height:6px;background-color: ' + ChangeColor + ';border-radius:50%;float:left"></div><div class="change-color-find" change-color="42" data-clistyle-brushtype="bg" style="margin:0 7px;padding:0;width:6px;height:6px;background-color: ' + ChangeColor + ';border-radius:50%;float:left;opacity:.6"></div><div  class="change-color-find" change-color="43" data-clistyle-brushtype="bg" style="margin:0;padding:0;width:6px;height:6px;background-color: ' + ChangeColor + ';border-radius:50%;float:left;opacity:.2"></div></div><div data-clistyle-brushtype="text" class="change-color-find" change-color="44" style="margin-top:5px;padding:0;text-align:center;color: ' + ChangeColor + ';"><strong><span style="color:inherit;font-size:16px" class="titlemodle-find">',
        '</span></strong></div></div></div></div>'
    ],
    [
        '<div class="titlemodle" data-index="5" data-in="s" data-se="false" class="m-title-base"><p data-clistyle-brushtype="bd" class="change-color-find" change-color="5" style="margin:0; border-top-width: 2px; border-bottom-width: 2px; border-left-width: 0;     border-right-width: 0; border-style: solid; border-color: ' + ChangeColor + '; background-color: #fdfdfd;"><span style="display:block; margin: 0;padding: 10px 0 10px 10px;font-size: 18px; font-family:Microsoft Yahei;" class="titlemodle-find">',
        '</span></p></div>'
    ],
    [
        '<div class="titlemodle" data-index="6" data-in="s" data-se="false" class="m-title-base"><div style="text-align: center;"><span data-clistyle-brushtype="text" class="change-color-find" change-color="61" style="box-sizing:border-box; color: ' + ChangeColor + '; font-family:Microsoft Yahei,microsoft yahei; font-size:16px; margin:0px; padding:0px">◆</span><span style="color:#0c0c0c; font-family:Microsoft Yahei,microsoft yahei; font-size:16px" class="titlemodle-find">',
        '</span><span class="change-color-find" change-color="62" data-clistyle-brushtype="text" style="color:' + ChangeColor + '; font-family:Microsoft Yahei,microsoft yahei; font-size:16px">◆</span></div></div>'
    ],
    [
        '<div class="titlemodle" data-index="7" data-in="s" data-se="false" class="m-title-base"><div style="border-top: 1px solid rgb(221, 221, 221); margin: 10px auto; box-sizing: border-box;"><p data-clistyle-brushtype="bd" class="change-color-find" change-color="7" style="padding-top: 6px; padding-right: 5px; padding-left: 5px; border-top: 2px solid ' + ChangeColor + '; display: inline-block; margin-top: -1px; margin-bottom: 0px; line-height: 1.1; font-size: 18px; white-space: normal;" class="titlemodle-find">',
        '</p></div></div>'
    ],
    [
        '<div class="titlemodle" data-index="8" data-in="s" data-se="false" class="m-title-base"><div style="box-sizing: border-box; word-break: break-all; word-wrap: break-word; max-width: 100%; border: none; margin: 5px;"><div data-clistyle-brushtype="bd" class="change-color-find" change-color="81" style="box-sizing: border-box; word-break: break-all; word-wrap: break-word; max-width: 100%; color: ' + ChangeColor + '; text-align: center; margin: 0px auto -2px; border-bottom: 2px solid ' + ChangeColor + '; border-top: 2px solid ' + ChangeColor + '; border-right-color: ' + ChangeColor + '; border-left-color: ' + ChangeColor + '; padding: 5px;"><p data-clistyle-brushtype="text" style="box-sizing: border-box; max-width: 100%; color: inherit; font-size: 18px;" class="titlemodle-find">',
        '</p></div><div data-clistyle-brushtype="bdt" class="change-color-find" change-color="82" style="box-sizing: border-box; word-break: break-all; word-wrap: break-word; max-width: 100%; width: 0px; margin-right: auto; margin-left: auto; border-top: 0.6em solid ' + ChangeColor + '; height: 10px; color: inherit; border-left: 0.7em solid transparent !important; border-right: 0.7em solid transparent !important;"></div><div style="box-sizing: border-box; word-break: break-all; word-wrap: break-word; max-width: 100%; width: 0px; margin-right: auto; margin-left: auto; border-top: 0.6em solid rgb(254, 254, 254); border-bottom-color: rgb(254, 254, 254); height: 10px; margin-top: -15.5px; color: inherit; border-left: 0.7em solid transparent !important; border-right: 0.7em solid transparent !important;"></div></div></div>'
    ],
]



////////////////////////////////////////////////////////////注释待删除///////////////////////////////////////////////////////





////插入模块列表
//function setModuleList(MaterialId) {
//        $.ajax({
//        type: "POST",
//        dataType: 'json',
//        url: "/Module/" + "getModuleListByModuleId?materialId=" + MaterialId,
//        cache: false,
//        success: function (data) {
//            data = mini.decode(data);
//            appendList(data);
//        }
//    });
//}

//$("#insertinfo").click(function () {
//        mini.open({
//        url: "/Material/" + "SuperEdit?batchId=" + entity.ProductBatch,
//        title: "高级编辑", width: 600, height: 480,
//        onload: function () {
//            var iframe = this.getIFrameEl();
//            $(iframe).parent().parent().parent().attr("style", "position:fixed;top:50px;width:500px;");
//        },
//        ondestroy: function (action) {

//        }
//    });
//});



function reback(data) {
    ue.focus();
    ue.execCommand('inserthtml', data);
}
